3.2.22 \(\int \frac {\sin ^n(e+f x)}{\sqrt {a+a \sin (e+f x)}} \, dx\) [122]

Optimal. Leaf size=60 \[ -\frac {F_1\left (\frac {1}{2};-n,1;\frac {3}{2};1-\sin (e+f x),\frac {1}{2} (1-\sin (e+f x))\right ) \cos (e+f x)}{f \sqrt {a+a \sin (e+f x)}} \]

[Out]

-AppellF1(1/2,-n,1,3/2,1-sin(f*x+e),1/2-1/2*sin(f*x+e))*cos(f*x+e)/f/(a+a*sin(f*x+e))^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.09, antiderivative size = 60, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {2866, 2864, 129, 440} \begin {gather*} -\frac {\cos (e+f x) F_1\left (\frac {1}{2};-n,1;\frac {3}{2};1-\sin (e+f x),\frac {1}{2} (1-\sin (e+f x))\right )}{f \sqrt {a \sin (e+f x)+a}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sin[e + f*x]^n/Sqrt[a + a*Sin[e + f*x]],x]

[Out]

-((AppellF1[1/2, -n, 1, 3/2, 1 - Sin[e + f*x], (1 - Sin[e + f*x])/2]*Cos[e + f*x])/(f*Sqrt[a + a*Sin[e + f*x]]
))

Rule 129

Int[((e_.)*(x_))^(p_)*((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> With[{k = Denominator[p]
}, Dist[k/e, Subst[Int[x^(k*(p + 1) - 1)*(a + b*(x^k/e))^m*(c + d*(x^k/e))^n, x], x, (e*x)^(1/k)], x]] /; Free
Q[{a, b, c, d, e, m, n}, x] && NeQ[b*c - a*d, 0] && FractionQ[p] && IntegerQ[m]

Rule 440

Int[((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_))^(q_), x_Symbol] :> Simp[a^p*c^q*x*AppellF1[1/n, -p,
 -q, 1 + 1/n, (-b)*(x^n/a), (-d)*(x^n/c)], x] /; FreeQ[{a, b, c, d, n, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[n
, -1] && (IntegerQ[p] || GtQ[a, 0]) && (IntegerQ[q] || GtQ[c, 0])

Rule 2864

Int[((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Dist[(-b)*(
d/b)^n*(Cos[e + f*x]/(f*Sqrt[a + b*Sin[e + f*x]]*Sqrt[a - b*Sin[e + f*x]])), Subst[Int[(a - x)^n*((2*a - x)^(m
 - 1/2)/Sqrt[x]), x], x, a - b*Sin[e + f*x]], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] &&  !
IntegerQ[m] && GtQ[a, 0] && GtQ[d/b, 0]

Rule 2866

Int[((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Dist[a^Int
Part[m]*((a + b*Sin[e + f*x])^FracPart[m]/(1 + (b/a)*Sin[e + f*x])^FracPart[m]), Int[(1 + (b/a)*Sin[e + f*x])^
m*(d*Sin[e + f*x])^n, x], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] &&  !IntegerQ[m] &&  !GtQ
[a, 0]

Rubi steps

\begin {align*} \int \frac {\sin ^n(e+f x)}{\sqrt {a+a \sin (e+f x)}} \, dx &=\frac {\sqrt {1+\sin (e+f x)} \int \frac {\sin ^n(e+f x)}{\sqrt {1+\sin (e+f x)}} \, dx}{\sqrt {a+a \sin (e+f x)}}\\ &=-\frac {\cos (e+f x) \text {Subst}\left (\int \frac {(1-x)^n}{(2-x) \sqrt {x}} \, dx,x,1-\sin (e+f x)\right )}{f \sqrt {1-\sin (e+f x)} \sqrt {a+a \sin (e+f x)}}\\ &=-\frac {(2 \cos (e+f x)) \text {Subst}\left (\int \frac {\left (1-x^2\right )^n}{2-x^2} \, dx,x,\sqrt {1-\sin (e+f x)}\right )}{f \sqrt {1-\sin (e+f x)} \sqrt {a+a \sin (e+f x)}}\\ &=-\frac {F_1\left (\frac {1}{2};-n,1;\frac {3}{2};1-\sin (e+f x),\frac {1}{2} (1-\sin (e+f x))\right ) \cos (e+f x)}{f \sqrt {a+a \sin (e+f x)}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(234\) vs. \(2(60)=120\).
time = 1.28, size = 234, normalized size = 3.90 \begin {gather*} \frac {\cos (e+f x) \sin ^{2 n}(e+f x) \left (-\sin ^2(e+f x)\right )^{-n} \sqrt {a (1+\sin (e+f x))} \left (1-\frac {1}{1+\sin (e+f x)}\right )^{-n} \left (4 F_1\left (-\frac {1}{2}-n;-\frac {1}{2},-n;\frac {1}{2}-n;\frac {2}{1+\sin (e+f x)},\frac {1}{1+\sin (e+f x)}\right ) (-\sin (e+f x))^n \sqrt {\frac {-1+\sin (e+f x)}{1+\sin (e+f x)}}-(1+2 n) F_1\left (1;\frac {1}{2},-n;2;\frac {1}{2} (1+\sin (e+f x)),1+\sin (e+f x)\right ) \sqrt {2-2 \sin (e+f x)} \left (1-\frac {1}{1+\sin (e+f x)}\right )^n\right )}{4 a f (1+2 n) (-1+\sin (e+f x))} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sin[e + f*x]^n/Sqrt[a + a*Sin[e + f*x]],x]

[Out]

(Cos[e + f*x]*Sin[e + f*x]^(2*n)*Sqrt[a*(1 + Sin[e + f*x])]*(4*AppellF1[-1/2 - n, -1/2, -n, 1/2 - n, 2/(1 + Si
n[e + f*x]), (1 + Sin[e + f*x])^(-1)]*(-Sin[e + f*x])^n*Sqrt[(-1 + Sin[e + f*x])/(1 + Sin[e + f*x])] - (1 + 2*
n)*AppellF1[1, 1/2, -n, 2, (1 + Sin[e + f*x])/2, 1 + Sin[e + f*x]]*Sqrt[2 - 2*Sin[e + f*x]]*(1 - (1 + Sin[e +
f*x])^(-1))^n))/(4*a*f*(1 + 2*n)*(-1 + Sin[e + f*x])*(-Sin[e + f*x]^2)^n*(1 - (1 + Sin[e + f*x])^(-1))^n)

________________________________________________________________________________________

Maple [F]
time = 0.10, size = 0, normalized size = 0.00 \[\int \frac {\sin ^{n}\left (f x +e \right )}{\sqrt {a +a \sin \left (f x +e \right )}}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(f*x+e)^n/(a+a*sin(f*x+e))^(1/2),x)

[Out]

int(sin(f*x+e)^n/(a+a*sin(f*x+e))^(1/2),x)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^n/(a+a*sin(f*x+e))^(1/2),x, algorithm="maxima")

[Out]

integrate(sin(f*x + e)^n/sqrt(a*sin(f*x + e) + a), x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^n/(a+a*sin(f*x+e))^(1/2),x, algorithm="fricas")

[Out]

integral(sin(f*x + e)^n/sqrt(a*sin(f*x + e) + a), x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\sin ^{n}{\left (e + f x \right )}}{\sqrt {a \left (\sin {\left (e + f x \right )} + 1\right )}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)**n/(a+a*sin(f*x+e))**(1/2),x)

[Out]

Integral(sin(e + f*x)**n/sqrt(a*(sin(e + f*x) + 1)), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^n/(a+a*sin(f*x+e))^(1/2),x, algorithm="giac")

[Out]

integrate(sin(f*x + e)^n/sqrt(a*sin(f*x + e) + a), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \int \frac {{\sin \left (e+f\,x\right )}^n}{\sqrt {a+a\,\sin \left (e+f\,x\right )}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(e + f*x)^n/(a + a*sin(e + f*x))^(1/2),x)

[Out]

int(sin(e + f*x)^n/(a + a*sin(e + f*x))^(1/2), x)

________________________________________________________________________________________